package com.ying.controller;

import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ziyan
 * @email 434595824@qq.com
 * @date 2017/9/25
 */
@Controller
@RequestMapping("/api")
public class TestContraller {

    @GetMapping("/test")
    public ResponseEntity test() {
        return ResponseEntity.ok("OK!!");
    }
    @GetMapping("/500")
    public String aa() {
        return "/error/500";
    }
}